package com.chf.aop;

import org.aspectj.lang.annotation.After;
import org.aspectj.lang.annotation.Before;
import org.springframework.stereotype.Component;
//让spring进行托管
@Component
//声明一个Aspect切面
@org.aspectj.lang.annotation.Aspect
public class Aspect {
    //配置切入点
    @Before("execution(* com.chf.service..*.*(..))")
    private void doBeforeLogin() {
        System.out.println("这里是PointCut之前的日志。。。。");
    }

    @After("execution(* com.chf.service..*.*(..))")
    private void doAfterLogin(){
        System.out.println("这里是PointCut之后的日志。。。。");
    }
}
